
#ifndef SENSORMONITOR_H
#define SENSORMONITOR_H
#include "SensorNotify.h"
#include <qobject.h> 
#include <qtimer.h>


class SensorMonitor : public QObject
{
	Q_OBJECT
	public:
		SensorMonitor();
		~SensorMonitor();

		void registerNotify(SensorNotify* sn[], int cnt, int index);
		void start();
		void stop();

		public slots:
			void readState();
	private:
		QTimer* m_timer;
		void initSensor();
		int m_fd;
		SensorState m_sensorState[1024];
#define SENSORNOTIFY_CNT 9
		SensorNotify* m_sensorNotify[SENSORNOTIFY_CNT];

};
#endif
